using System;
using System.Collections.Generic;
using System.Text;
using System.ComponentModel.Design;
using System.ComponentModel;
using System.Reflection;
using System.Collections;
using System.Windows.Forms;

namespace XnaDesignerGenerator
{
    public class XnaGameComponentDesigner : ComponentDesigner
    {
        protected override void PostFilterProperties(System.Collections.IDictionary properties)
        {
            IList propertiesToRemove = new ArrayList();
            foreach (object o in properties)
            {
                DictionaryEntry de = (DictionaryEntry)o;
                object key = de.Key;
                PropertyDescriptor property = (PropertyDescriptor)properties[key];
                if (property.DisplayName == "GenerateMember" || property.DisplayName == "Modifiers")
                    propertiesToRemove.Add(key);
            }
            foreach (object key in propertiesToRemove)
                properties.Remove(key);
            base.PostFilterProperties(properties);
        }
    }
}
